package com.hykc.auth.common.vo;

import com.aopuxun.common.exceptions.DdException;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import org.joda.time.DateTime;

@Getter
@AllArgsConstructor
@NoArgsConstructor
public class ExceptionResult {
    private int status;
    private String message;
    private String timeStamp;

    public ExceptionResult(DdException e) {
        this.status = e.getStatus();
        this.message = e.getMessage();
        this.timeStamp = DateTime.now().toString("yyyy-MM-dd HH:mm:ss");
    }
}
